package com.heima.comment.feign;

import com.heima.comment.entity.ApArticle;
import com.heima.common.dto.ResponseResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;

import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient("leadnews-article")
@Component
public interface ArticleFeign {


    /**
     * 根据文章id查询文章
     * @param id
     * @return
     */
    /*@PostMapping("/api/v1/article/select")
    public ResponseResult<ApArticle> select(@RequestParam Long id);*/

    @PostMapping("/api/v1/article/update")
    public ResponseResult<ApArticle> update(@RequestParam Long id);

    @PostMapping("/api/v1/article/findArticle")
    public ApArticle findArticle(@RequestBody Long id);
}
